import 'package:flutter/cupertino.dart';
import 'package:lepig/model/ProductInfoModel.dart';
import 'lib/HttpManager.dart';
import 'lib/NWApi.dart';
import 'lib/NWMethod.dart';

//获取url商品详情
Future<ProductInfoModel> HttpUrlProductDetails(BuildContext context,String url) async {
      Map<String, dynamic> params = new Map();
       params['url']=url;
  Map responseBody =  await HttpManager().request(NWApi.getFetchByUrl, NWMethod.GET,params:params,context: context);
  Map data = responseBody["data"];
  return ProductInfoModel.fromJson(data);
}


